package com.company.cloud.goodsrestservice.dao;

import com.company.cloud.goodsrestservice.core.Mapper;
import com.company.cloud.goodsrestservice.model.Sku;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface SkuMapper extends Mapper<Sku> {
	//执行SQL语句
	public List<Sku> executeSql(String sql);
	//传入Where 获取SKU 列表
	public List<Sku> getList(String where);
    //通过orderId获取SKU List
	public List<Sku> getSkuByOrderId(String where);
	//更新库存,返回影响行数
	public Integer updateStock(
            @Param(value = "materialNumber") String materialNumber,
            @Param(value = "stock") Integer stock,
            @Param(value = "locationId") Integer locationId);
}
